package com.bailong.nanny.entity;

import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;

/**
 * 保存表的分页数据
 */

public class Page<T> {
    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }

    public int getPageCount() {
        return pageCount;
    }

    public void setPageCount(int pageCount) {
        this.pageCount = pageCount;
    }

    public int getCurrentPage() {
        return currentPage;
    }

    public void setCurrentPage(int currentPage) {
        this.currentPage = currentPage;
    }

    //分页行数
    public static final int PAGE_SIZE=10;
    //保存分页的数据
    private List<T> list;
    //保存页面数量
    private int pageCount;
    //保存当前页数
    private int currentPage;

    public Page(List<T> list, int pageCount, int currentPage) {
        this.list = list;
        this.pageCount = pageCount;
        this.currentPage = currentPage;
    }
    public Page(){};
}
